package com.ruoyi.swla2.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 设备台账对象 t_device
 *
 * @author jipf
 * @date 2025-07-24
 */
@TableName("t_device")
public class Device extends CommonEntity
{
    private static final long serialVersionUID = 1L;

    /**  主键id */
    @TableId(value="id",type = IdType.AUTO)
    private Long id;

    /** 设备编号 */
    @Excel(name = "设备编号")
    @TableField("device_num")
    private String deviceNum;

    /** 安装时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "安装时间", width = 30, dateFormat = "yyyy-MM-dd")
    @TableField("install_time")
    private Date installTime;

    /** 安装位置 */
    @Excel(name = "安装位置")
    @TableField("install_position")
    private String installPosition;

    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId()
    {
        return id;
    }
    public void setDeviceNum(String deviceNum)
    {
        this.deviceNum = deviceNum;
    }

    public String getDeviceNum()
    {
        return deviceNum;
    }
    public void setInstallTime(Date installTime)
    {
        this.installTime = installTime;
    }

    public Date getInstallTime()
    {
        return installTime;
    }
    public void setInstallPosition(String installPosition)
    {
        this.installPosition = installPosition;
    }

    public String getInstallPosition()
    {
        return installPosition;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("deviceNum", getDeviceNum())
            .append("installTime", getInstallTime())
            .append("installPosition", getInstallPosition())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
